package com.ctshk.rpc.train.req;

import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import org.springframework.format.annotation.DateTimeFormat;

import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotEmpty;
import javax.validation.constraints.NotNull;
import java.io.Serializable;
import java.math.BigDecimal;
import java.time.LocalDate;
import java.util.List;

/**
 * <p>
 * 火车票产品预订设置入参req
 * </p>
 *
 * @author 彭柳霖
 * @since 2021-03-11
 */
@Data
@ApiModel(value="TrainProductReservationSettingsReq对象", description="火车票产品预订设置入参req")
public class TrainProductReservationSettingsReq implements Serializable {

    private static final long serialVersionUID = 1L;

    @ApiModelProperty(value = "id")
    private Long id;

    @NotNull(message = "火车票产品id不能为空")
    @ApiModelProperty(value = "火车票产品id",required = true)
    private Long trainProductId;

    @NotNull(message = "開售時間不能為空")
    @ApiModelProperty(value = "开售类型（1：立即开售 2：定时开售）",required = true)
    private Integer saleType;

    @DateTimeFormat(pattern = "yyyy-MM-dd")
    @ApiModelProperty(value = "开售开始时间")
    private LocalDate saleBeginDate;

    @DateTimeFormat(pattern = "yyyy-MM-dd")
    @ApiModelProperty(value = "开售结束时间")
    private LocalDate saleEndDate;

    @NotNull(message = "預訂確認不能為空")
    @ApiModelProperty(value = "是否二次确认")
    private Integer isConfirm;

    @NotBlank(message = "預訂須知不能為空")
    @ApiModelProperty(value = "预订须知",required = true)
    private String bookingInformation;

    @NotBlank(message = "乘客须知不能為空")
    @ApiModelProperty(value = "乘客须知",required = true)
    private String passengerNotice;

    @ApiModelProperty(value = "小童订票须知")
    private String childrenNotice;

    @ApiModelProperty(value = "电子客票说明")
    private String electronicTicketExplain;

    @NotNull(message = "取消政策不能為空")
    @ApiModelProperty(value = "退改设置")
    private Integer changeSettings;

    @NotNull(message = "預訂服务费类型不能為空")
    @ApiModelProperty(value = "服务费类型(1:数值 2：百分比)",required = true)
    private Integer serviceChargeType;

    @ApiModelProperty(value = "服务费")
    private BigDecimal serviceChargePrice;

    @NotNull(message = "退改手续费类型不能為空")
    @ApiModelProperty(value = "退改手续费类型",required = true)
    private Integer refundFeeType;

    @ApiModelProperty(value = "退改手续费")
    private BigDecimal refundFeePrice;

    @NotNull(message = "取票类型不能為空")
    @ApiModelProperty(value = "取票类型(1：电子票 2：纸质票)",required = true)
    private Integer ticketCollectionType;

    @NotEmpty(message = "取票方式不能為空")
    @ApiModelProperty(value = "取票类型对应方式")
    private List<String> ticketCollectionList;

    @NotNull(message = "使用方式不能為空")
    @ApiModelProperty(value = "兑换方式",required = true)
    private Integer exchangeMethod;

    @ApiModelProperty(value = "保存方式 1-保存  2-提交审批保存")
    private Integer saveType;


}
